<!DOCTYPE html>
<html>
	<head>
		<meta charset="utf-8">
		<title></title>
	</head>
	<body>
		<script src="../js/vue.js"></script>
		<div id="app">
			{{firstName + " " +lastName}}
			<h1>{{countName()}}</h1>
			<h1>{{fullname}}</h1>
		</div>
		<script>
			var app = new Vue({
				el: '#app',
				data: {
					firstName:"我是",
					lastName:"你爸爸",
				},
				computed:{
					fullname:function(){
						return this.firstName+" "+this.lastName
					}
				},
				methods: {
					countName(){
						return this.firstName+" "+this.lastName
					}
				}
			})
		</script>
	</body>
</html>
